import Vue from 'vue'
import App from './App.vue'
import VueI18n from "vue-i18n";
import router from './router/index'
Vue.use(VueI18n).use(router);
const i18n = new VueI18n({
  locale:
      localStorage.getItem("lang") == (undefined || "" || null)
          ? "zh"
          : localStorage.getItem("lang"),
  messages: {
    zh: require("../static/lang/text-zh.json"),
    en: require("../static/lang/text-en.json")
  }
});

Vue.config.productionTip = false

new Vue({
  i18n,
  router,
  render: h => h(App),
}).$mount('#app')
